package com.example.springbootsfzy.mapper;

import com.example.springbootsfzy.domain.ConsultationReviews;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
* @author 30658
* @description 针对表【consultation_reviews】的数据库操作Mapper
* @createDate 2025-01-02 15:11:36
* @Entity com.example.springbootsfzy.domain.ConsultationReviews
*/
public interface ConsultationReviewsMapper {

    int deleteByPrimaryKey(Long id);

    int insert(ConsultationReviews record);

    int insertSelective(ConsultationReviews record);

    ConsultationReviews selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(ConsultationReviews record);

    int updateByPrimaryKey(ConsultationReviews record);

    //1.查询列表所有内容
    List<ConsultationReviews> selectAll();

    //2.添加新评价
    int addConsultationReviews(ConsultationReviews consultationReviews);

    //3.根据memberId查询
    List<ConsultationReviews> selectByMemberId(int id);

    //4.根据consultationId查询
    List<ConsultationReviews> selectByConsultationId(int id);

    //5.删除该评价
    int deleteByReviewId( int id);

    //修改评价
    int updateByReviewId(ConsultationReviews consultationReviews);

}
